Skip to content

[ENH] Enable background jobs for custom data handles (#7)#47

Merged
Shashankss1205 merged 3 commits into
sktime:mainfrom
Abhishek9639:custom-data-handles
Apr 27, 2026
Merged

[ENH] Enable background jobs for custom data handles (#7)#47
Shashankss1205 merged 3 commits into
sktime:mainfrom
Abhishek9639:custom-data-handles

Conversation

@Abhishek9639
Copy link
Copy Markdown
Contributor

Reference Issues/PRs

Fixes #7

What does this implement/fix? Explain your changes.

Updated fit_predict_async to support custom data handles alongside demo datasets. Previously it only worked with built-in datasets like "airline" now users can pass a data_handle from load_data_source to train models on their own data in the background.

Changes:

  • Added optional data_handle parameter to fit_predict_async_tool in fit_predict.py.
  • Updated Executor.fit_predict_async to branch between demo dataset and custom data handle.
  • Updated the server tool schema and dispatch to pass through the new parameter.
  • Added validation so exactly one of dataset or data_handle must be provided.
  • Added tests covering both data sources and error cases.

Does your contribution introduce a new dependency? If yes, which one?

No.

What should a reviewer concentrate their feedback on?

  • The validation logic in fit_predict_async_tool making sure the either/or check is solid.
  • The data loading branch in Executor.fit_predict_async the data_handle path vs the dataset path.

Any other comments?

Backward compatible existing calls with dataset= still work exactly as before.

PR checklist

For all contributions
  • I've added myself to the list of contributors.
  • Optionally, I've updated sktime's CODEOWNERS to receive notifications about future changes to these files.
  • I've added unit tests and made sure they pass locally.
For new estimators
  • I've added the estimator to the online documentation.
  • I've updated the existing example notebooks or provided a new one to showcase how my estimator works.

@Abhishek9639
Copy link
Copy Markdown
Contributor Author

Greetings @Shashankss1205,
This is ready for review. All 3 test pipelines (Python 3.10, 3.11, 3.12) are passing.

The 2 remaining CI failures are pre-existing on main as well.

Let me know if anything needs to be changed.
Thanks

@Shashankss1205
Copy link
Copy Markdown
Collaborator

Please pull the latest commit and then make this PR, also try to ensure the ruff tests pass.
Thanks!

@Abhishek9639
Copy link
Copy Markdown
Contributor Author

Got it, I’ll pull the latest changes and make sure the ruff tests pass before opening the PR. Thanks!

@Abhishek9639 Abhishek9639 force-pushed the custom-data-handles branch from 815aa86 to dfa35bc Compare April 4, 2026 19:45
@Abhishek9639
Copy link
Copy Markdown
Contributor Author

Greetings @Shashankss1205,
Done. Rebased on the latest main and resolved the merge conflicts. All ruff checks and tests are passing now.
Please review when you get a chance.
Thanks

@Abhishek9639
Copy link
Copy Markdown
Contributor Author

Greetings @Shashankss1205,

Rebased on the latest main and resolved the merge conflicts.
Ready for review whenever you get a chance.
Thanks

@Shashankss1205
Copy link
Copy Markdown
Collaborator

Hey @Abhishek9639 the tests are failing and am still merging this. This is happening only because the tests are wrong. We will be rewriting most of the tests again.

@Shashankss1205 Shashankss1205 merged commit 04644b9 into sktime:main Apr 27, 2026
1 of 5 checks passed
@Abhishek9639
Copy link
Copy Markdown
Contributor Author

Hey @Abhishek9639 the tests are failing and am still merging this. This is happening only because the tests are wrong. We will be rewriting most of the tests again.

Got it, thanks for the clarification. That makes sense.
I'll wait for the updated tests and align my changes accordingly. Let me know if you'd like me to help with anything in the meantime.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[ENH] Enable Background Jobs for Custom Data Handles

2 participants